<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>登陆</title>
    <link rel="stylesheet" href="/manager/css/login.css">
    <script src="/manager/js/jquery-1.4.2.min.js"></script>
    <!--背景图片自动更换-->
    <script src="/manager/js/supersized.3.2.7.min.js"></script>
    <script src="/manager/js/login-page/login-supersized-init.js"></script>
    <script>
        $(() => {
            //登录
            $("#submit").click(() => {
                $.ajax({
                    url: "/manager/managerUser/login",
                    type: "post",
                    data: $("#loginForm").serialize(),
                    success: function (rs) {
                        if (rs.status == 200) {
                            location.href = "/manager/showIndex";
                        } else {
                            alert(rs.msg);
                        }
                    }
                });
            });


        });
    </script>

</head>
<body>
<div class="login-container">
    <h1>ITANY 书城</h1>
    <div class="connect">
        <p>后台维护管理系统</p>
    </div>
    <form action="" method="post" id="loginForm">
        <div>
            <input type="text" name="username" class="username" placeholder="用户名" autocomplete="off"/>
        </div>
        <div>
            <input type="password" name="password" class="password" placeholder="密码" oncontextmenu="return false"
                   onpaste="return false"/>
        </div>
        <button id="submit" type="button">登 陆</button>
    </form>
</div>
</body>
</html>